$OpenBSD: patch-bin_plugin,v 1.2 2015/06/14 09:16:59 jasper Exp $
--- bin/plugin.orig	Thu Jun 11 14:48:06 2015
+++ bin/plugin	Thu Jun 11 14:49:34 2015
@@ -59,6 +59,8 @@ if [ -n "$ES_ENV_FILE" ]; then
   fi
 fi
 
+JAVA_HOME="$(${TRUEPREFIX}/bin/javaPathHelper -h elasticsearch)"
+
 if [ -x "$JAVA_HOME/bin/java" ]; then
     JAVA=$JAVA_HOME/bin/java
 else
